music_table = \
(
    ("{'SPEED':0}",),
    ("0", "0"),
    ("3+:2+:6+:2+:3+:2+:6:2+=1/8", ),
    ("3+:2+:6+:2+:3+:2+:6:2+=1/8", ),
    ("3+:2+:6+:2+:3+:2+:6:2+=1/8", ),
    ("3+:2+:6+:2+:3+:2+:6:2+=1/8", ),
    #5
    ("3+:2+:6+:2+:3+:2+:6:2+=1/8", ),
    ("3+:2+:6+:2+:3+:2+:6:2+=1/8", ),
    ("3+:2+:6+:2+:3+:2+:6+:2+=1/8", ),
    ("{'NOP':1/24}",),
    ("3++:2++:6+:3+=1/32", "0=28/32"),
    #9
    ("{'BEAT':96}",),
    ("3+=1/4", "0:6:1+:3+=1/16", "2+,7,5=1/4", "5:2+:7=1/32", "0=5/32"),
    ("2+,7=3/16", "7+=1/16", "6+=3/16", "5+#=1/16", "6+:3++=1/4"),
    ("6+,4+=7/32", "6+=1/32", "3++=1/4", "2++=1/8", "2++:3++:2++=1/24", "7+:5+=1/8"),
    #12
    ("6+=3/4", "0:3+=1/8"),
    ("3+,1+,6=1/32", "0=5/32", "0:6:1+:3+=1/16", "2+,7,5:5+,2+,7=1/4"),
    ("2+,7:5+#,7:6+:7+=1/8", "3+:1++:2+:7+:1+:6+:7:5+=1/16"),

    #15
    ("6+:3++:2++:3++:6+:3++:2++:3++:6+:3++:2++:3++:6+:3++:2++:3++=1/16"),
    ("6+:3++:1++#:3++:6+:3++:1++#:3++:6+:3++:1++#:3++=1/16","6+:3+=1/8"),
    ("1++:3+:7+:3+:1++:3+:2++:3+:7+:3+:6+:3+=1/16", "5+=1/8", "3+:5+=1/16"),

    #18
    ("6+:1+:5+:1+:6+:1+:1++:1+:5+:1+:4+:1+=1/16", "3+=1/8", "3+:5+=1/16"),
    ("4+:6:3+:6:2+:6:4+:6:3+:6:2+:6:1+:6+3+:6=1/16",),
    ("2+:4+:1+:4:7:4:6:4=1/16", "5#,3:6,3:7,3:3=1/8"),

    #21
    ("1+:3:7:3:1+:3:2+:3:7:3:6:3=1/16", "5=1/8", "3:5=1/16"),
    ("6:1:5:1:6:1:1+:1:5:1:4:1=1/16", "3=1/8", "3:5=1/16"),
    ("4=1/8", "4+:3+:2+:1+=1/16", "7=1/8", "3+:2+:3+:4+:3+:2+:1+:7=1/16"),

    #24
    ("6:3+:5+#:3+=1/8", "6:7=1/16", "6=6/16"),


)


music_table_left = \
(
    ("{'SPEED':10}",),
    ("0", "0"),
    ("4-:1:4:5=1/8", "5=1/2"),
    ("5-:2:5:6=1/8", "7=1/2"),
    ("6-:3:6:7=1/8", "1+=1/2"),
    ("0=1/1",),
    #5
    ("4-:1:4:5=1/8", "5=1/2"),
    ("5-:2:5:6=1/8", "7=1/2"),
    ("6-:3:6:7=1/8", "1+=1/2"),
    ("{'NOP':1/24}",),
    ("2+:6:3=1/32", "0=29/32"),
    #9
    ("{'BEAT':96}",),
    ("0=1/8", "1=3/8", "5-:2=1/8", "5=1/4"),
    ("3-:7-:3:5#:6-:3:6:3=1/8",),
    ("4-:1:4:1:5-:2:5:2=1/8",),
    #12
    ("6-:3:6:7:1+:3=1/8", "6=1/4"),
    ("4-=1/16", "1=3/8", "5-:2=1/8", "5=1/4"),
    ("3-:7-=1/8", "3=1/4", "6-:3=1/8", "6=1/4"),
    #15
    ("4-:1=1/8", "4=1/4", "5-:2=1/8", "5=1/4"),
    ("6-:3:6:7=1/8", "1+#=1/2"),
    ("6--:3-:1,6-:3-:3-:7-:5,3:7-=1/8",),

    #18
    ("4--:1-:6-,4-:1-:1-:5-:3,1:5-=1/8",),
    ("2--:6--:4-,2-:6--:6--:3-:1,6-:3-",),
    ("7--:4-#:2,7-:4-:2,3-:1,4-=1/16", "7,5-#=1/4"),
)

import sys,time
sys.path.append('../')

import music_translate
music_parse = music_translate.music_trans([music_table_left, music_table,], beat = 82)
music_parse.music_to_play_table()
music_parse.play_music()
